package cn.tangsihai.hrm;

import cn.tangsihai.hrm.exceptions.GlobalExceptionHandler;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.Import;

@SpringBootApplication
@EnableEurekaClient
@Import({GlobalExceptionHandler.class})
@EnableCaching // 开启SpringCach缓存扫描
// 扫描feign注解  cn.tangsihai.hrm.client：要扫描的Feign所在的包
@EnableFeignClients(basePackages = "cn.tangsihai.hrm.client")
public class CourseApplication {
    public static void main(String[] args) {
        SpringApplication.run(CourseApplication.class);
    }
}
